//package com.wulian.user.task;
//
//import java.util.Map;
//
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.data.redis.core.RedisTemplate;
//import org.springframework.scheduling.annotation.Scheduled;
//import org.springframework.stereotype.Component;
//
//import com.wulian.user.service.SysUserService;
//
//
//@Component
//public class TaskService {
//
//    @Autowired
//    RedisTemplate redisTemplate;
//
//    @Autowired
//    private SysUserService sysUserService;
//    private static final long TOKEN_EXPIRE_TIME = 60 * 60 * 24 * 30 * 12;
//
//    //@Scheduled(fixedRate = 1000 * 60 * 1, initialDelay = 2000)//项目启动2秒中之后执行一次，然后每10min执行一次，单位都为ms
//    public void getEarlyWarningSettings() {
//        //1. 获取token
//        Map<String, String> redisData = sysUserService.getUserInfoMap();
//        redisTemplate.opsForHash().putAll("userInfoMap", redisData);
//    }
//
//}